/* CSS FORMATTING */

html {
    scroll-behavior: smooth;
}

body {
    font-family: "Segoe UI", "Helvetica Neue", Arial, sans-serif;
    font-size: small;
    margin: 0;
    padding: 0;
    line-height: 1.6;
    background-color: whitesmoke;
    color: #333;
    counter-reset: h2;
}

/* Enumerated Section */
h2.counter {
    counter-increment: h2;
    counter-reset: h3;
}

h2.counter:before {
    content: counter(h2) ". ";
}

h3.counter {
    counter-increment: h3;
}

h3.counter::before {
    content: counter(h2) "." counter(h3) " ";
}

header {
    /* background-color: rgb(40, 215, 180); */
    background-color: cadetblue;
    color: white;
    padding-top: 3%;
    padding-bottom: 3%;
    font-family: 'Poppins', sans-serif;
    text-align: center;
    font-size: small;
}

footer {
    /* background-color: rgb(55, 130, 180); */
    background-color: cadetblue;
    margin-top: 8rem;
    font-family: 'Poppins', sans-serif;
    color: white;
    padding: 1.4%;
    text-align: right;
    font-size: small;
}

footer a:hover {
    text-decoration: underline;
    text-decoration-thickness: 0.14rem;
    text-underline-offset: 0.2rem;
    color: black;
}

nav a {
    color: white;
    font-weight: bold;
    text-decoration: none;
    margin: 0 1%;
}

nav a:hover {
    text-decoration: underline;
    text-decoration-thickness: 0.14rem;
    text-underline-offset: 0.2rem;
    color: black;
}

a {
    color: rgb(55, 130, 180);
    text-decoration: none;
}

a:hover {
    text-decoration: none;
    color: rgb(40, 215, 180);
}

main {
    font-size: small;
}

blockquote {
    border-left: 4px solid #ccc;
    padding-left: 1%;
    padding-right: 1%;
    margin: 1% 0;
    font-style: italic;
}

img.featured {
    max-width: 60%;
}

table {
    border-collapse: collapse;
    width: 60%;
    border: 1;
}
th, td {
    padding: 8px 12px;
    border: 1px solid #ccc;
    text-align: center;
}
thead {
    background-color: #f2f2f2;
}


/* CUSTOMIZED */
.home_title {
    padding-top: 2%;
    /* padding-left: 4%; */
    font-family: 'Poppins', sans-serif;
    font-weight: bold;
    font-size: 400%;
    text-align: center;
    /* color: rgb(40, 215, 180); */
    color: cadetblue;
}

img.home {
    max-width: 40%;
}

.home_subtitle {
    padding-top: 0;
    /* padding-left: 4%; */
    font-family: 'Poppins', sans-serif;
    font-weight: bold;
    font-size: 150%;
    text-align: center;
    /* color: rgb(55, 130, 180); */
    color: slategray;
}

.content {
    max-width: 80%;
    margin-left: auto;
    margin-right: auto;
    color: #333;
}

.feat_title {
    color: white;
    text-align: center;
    font-family: 'Poppins', sans-serif;
    font-weight: bold;
    font-size: 150%;
}

.feat_title a {
    color: white;
}

.feat_title a:hover {
    text-decoration: underline;
    text-decoration-thickness: 0.3rem;
    text-underline-offset: 0.4rem;
    color: black;
}

.quotation_pic {
    max-width: 25%;
}

.offer {
    padding: 2% 3%;
    background-color: rgb(40, 215, 180);
    /* background-color: slategray; */
    border: none;
    border-radius: 0.2rem;
    margin: 0.5%;
    font-family: 'Poppins', sans-serif;
    font-size: medium;
    font-weight: bold;
    color: white;
    /* text-decoration: none; */
    /* text-underline-offset: 0.4rem; */
}

.offer-env{
    text-align: center;
    margin-top: 6%;
    margin-bottom: 10%;
}

.offer:hover {
    color: black;
    background-color: cadetblue;
    cursor: pointer;
}

.socmed_title {
    padding-top: 0%;
    padding-left: 4%;
    font-weight: bold;
    text-align: left;
}

.socmed_icon {
    display: flex;
    align-items: center;
    padding-top: 0.4%;
    text-align: left;
    font-size: small;
}

.socmed_icon a {
    color: white;
    text-decoration: none;
}

.socmed_icon img {
    padding-left: 4%;
    max-width: 4%;
    margin-right: 1.4%;
}

.logo {
    max-width: 10%;
    margin-top: 2%;
    margin-bottom: 4%;
}

.boxed_content {
    padding-top: 2%;
    padding-bottom: 2%;
    padding-left: 4%;
    padding-right: 4%;
    max-width: 80%;
    display: block;
    border: 0 solid;
    /* border: 0.6px solid rgb(220, 220, 220); */
    /* background-color: white; */
    background-color: slategray;
    border-radius: 0.3rem;
    margin-left: auto;
    margin-right: auto;
    margin-top: 1.8rem;
    color: white;
}

.boxed_content-title {
    color: white;
}

.boxed_content a {
    color: lightskyblue;
    /* font-weight: bold; */
}

.boxed_content a:hover {
    color: black;
    /* font-weight: bold; */
}

.opening {
    margin-top: 4rem;
    margin-left: auto;
    margin-right: auto;
    margin-bottom: 4rem;
    text-align: center;
    max-width: 80%;
}

.opening-title {
    margin-top: 4%;
    font-family: 'Poppins', sans-serif;
    font-weight: bold;
    font-size: 200%;
    /* color: rgb(40, 215, 180); */
    color: cadetblue;
}

.opening-bar {
    max-width: 4rem;
    height: 0.4rem;
    border: none;
    /* background-color: rgb(55, 130, 180); */
    background-color: slategray;
}

.opening-caption {
    margin-top: 2%;
}

.about-title {
    padding-top: 4rem;
    font-size: 240%;
    font-weight: bold;
    /* color: rgb(40, 215, 180); */
    color: cadetblue;
    max-width: 90%;
    margin-left: auto;
    margin-right: auto;
}

.article {
    margin-top: 2%;
    margin-bottom: 4%;
    text-align: center;
    font-family: 'Poppins', sans-serif;
}

.article-title {
    font-weight: bold;
    font-size: large;
}

.article-author {
    margin-top: 4%;
    font-size: medium;
}

.article-author img {
    max-width: 4%;
}

.anecdote-title {
    text-align: center;
    font-weight: bold;
}

.article-open-env {
    margin-top: 0.5rem;
    text-align: right;
}

.article-open {
    padding: 2% 3%;
    border: 0 solid;
    background-color: rgb(40, 215, 180);
    border-radius: 0.2rem;
    color: white;
    font-family: 'Poppins', sans-serif;
    font-weight: bold;
}

.article-open:hover {
    background-color: white;
    color: black;
    cursor: pointer;
}


/* TABLE OF CONTENT: toc */

.toc-subsection {
    padding-left: 1rem;
}

.toc-subsubsection {
    padding-left: 2rem;
}

.thm {
    color: rgb(50, 90, 125);
}

.thm a {
    color: rgb(40, 215, 180);
}

.thm a:hover {
    color: rgb(55, 130, 180);
}

.thm-qed {
    text-align: center;
    font-weight: bold;
}

.mini-game {
    background-color: white;
    max-width: 100%;
    padding: 1rem;
    border: 0.1rem solid lightgray;
    border-radius: 0.2rem;
    margin-top: 1rem;
    margin-bottom: 0.5rem;
    /* margin-left: auto;
    margin-right: auto; */
    color: rgb(50, 90, 125);
}

.mini-game a {
    color: rgb(40, 215, 180);
}

.mini-game a:hover {
    color: black;
}

/* SIDEBAR TABLE OF CONTENT */
.sidebar {
    max-width: 80%;
    margin-left: auto;
    margin-right: auto;
    color: rgb(50, 90, 125);
}

.article-content {
    max-width: 80%;
    margin-left: auto;
    margin-right: auto;
}

.side-toc {
    margin-bottom: 4rem;
}

.project-tag {
    background-color: rgb(40, 215, 180);
    border-radius: 0.2rem;
    padding-top: 0.2rem;
    padding-bottom: 0.2rem;
    padding-left: 0.4rem;
    padding-right: 0.4rem;
    margin-right: 0.4rem;
    color: white;
    font-weight: bold;
    font-size: small;
}

.project-tag a {
    color: white;
}

.project-tag a:hover {
    color: black;
}


/* FOR DESKTOP */
@media (min-width: 800px) {
    body {
        font-size: medium;
    }

    header {
        font-size: medium;
        padding-top: 1.4%;
        padding-bottom: 1.4%;
    }

    footer {
        font-size: medium;
    }

    main {
        font-size: medium;
    }

    nav a {
        color: white;
        font-weight: bold;
        text-decoration: none;
        margin: 0 1%;
    }

    nav a:hover {
        text-decoration: underline;
        text-decoration-thickness: 0.2rem;
        text-underline-offset: 0.4rem;
        color: black;
    }

    img.featured {
        max-width: 30%;
    }

    img.home {
        max-width: 20%;
    }

    .content {
        width: 60vw;
        margin-left: 20vw;
        margin-right: 20vw;
    }

    .quotation_pic {
        max-width: 10%;
    }

    .offer {
        padding: 1% 2%;
        /* border: none; */
        /* border-radius: 0.2rem; */
        margin: 0.5%;
        /* font-family: 'Poppins', sans-serif; */
        font-size: large;
        font-weight: bold;
        /* color: white; */
        /* text-decoration: none; */
        /* text-underline-offset: 0.4rem; */
    }

    .socmed_icon {
        display: flex;
        align-items: center;
        padding-top: 0.4%;
        text-align: left;
        font-size: medium;
    }

    .socmed_icon img {
        padding-left: 4%;
        max-width: 1.4%;
        margin-right: 1%;
    }

    .logo {
        max-width: 4%;
        margin-top: 1%;
        margin-bottom: 2%;
    }

    .boxed_content {
        padding-right: 4%;
        max-width: 60%;
        border-radius: 0.2rem;
        margin-top: 2rem;
    }

    .about-title {
        font-size: 400%;
    }

    .article-title {
        font-weight: bold;
        font-size: larger;
    }

    .article-author {
        font-size: large;
    }

    .article-author img {
        max-width: 1.5%;
    }

    .article-open {
        padding: 1% 2%;
        font-size: medium;
    }

    .article-open-env {
        margin-top: 2rem;
    }

    .side-toc {
        display: flex;
        margin-bottom: 4rem;
    }

    .sidebar {
        position: sticky;
        top: 1vh;
        left: 0;
        width: 17vw;
        padding-left: 1vw;
        padding-right: 2vw;
        height: 100vh;
        overflow-y: auto;
    }

    .article-content {
        width: 60vw;
        left: 20vw;
    }

    .right-bar {
        width: 20vw;
    }
}